package c.h.a.f0;

import android.content.Context;
import android.content.Intent;
import android.content.SharedPreferences;
import c.h.b.d.a.b;
import c.h.b.d.a.c;
import c.h.b.d.a.f;
import c.h.b.d.a.g;
import c.h.b.d.a.h;
import c.h.b.d.a.i;
import com.liuzh.deviceinfo.DeviceInfoApp;
import java.util.List;
import java.util.concurrent.CopyOnWriteArrayList;

/* compiled from: ProManager */
public class j implements c {
    public static final j d = new j();
    public c a = new c.h.b.d.a.j();
    public SharedPreferences b = DeviceInfoApp.c.getSharedPreferences("com.liuzh.deviceinfo_pro_pref", 0);
    public final CopyOnWriteArrayList<a> c = new CopyOnWriteArrayList();

    /* compiled from: ProManager */
    public interface a {
        void i(boolean z);
    }

    public void a(Intent intent, c.h.b.d.a.a aVar) {
        this.a.a(intent, aVar);
    }

    public void b(Context context, Intent intent, b bVar) {
        this.a.b(context, intent, bVar);
    }

    public void c(Context context, int i, g gVar) {
        this.a.c(context, i, gVar);
    }

    public void d(Context context, int i, List<String> list, h hVar) {
        this.a.d(context, i, list, hVar);
    }

    public void e(Context context, String str, int i, f fVar) {
        this.a.e(context, str, i, fVar);
    }

    public void f(Context context, i iVar) {
        this.a.f(context, iVar);
    }

    public void g() {
        c.b.a.a.a.p(this.b, "is_pro_user", true);
        c.h.a.m0.i iVar = c.h.a.m0.i.a;
        iVar = c.h.a.m0.i.a;
        synchronized (this.c) {
            c.h.a.m0.p.a.b(new f(this, true));
        }
    }

    public void h(a aVar) {
        synchronized (this.c) {
            if (!this.c.contains(aVar)) {
                this.c.add(aVar);
            }
        }
    }

    public boolean i() {
        return this.b.getBoolean("is_pro_user", false);
    }

    public void j(a aVar) {
        synchronized (this.c) {
            this.c.remove(aVar);
        }
    }
}
